<?php
namespace Admin\Controller;
use Think\Controller;
use Think\Page;
use Common\Controller\BaseController;
class CheckController extends BaseController{
    public function View(){
        $Staffinfo=D('Staff');
        $count=$Staffinfo->count();
        $page=new Page($count, 15);
        $page->setConfig('first', '首页');
        $page->setConfig('prev', '上一页');
        $page->setConfig('next', '下一页');
        $page->setConfig('last', '末页');
        $page->rollPage='10';
        $page->setConfig('theme', '%HEADER%  共    %TOTAL_PAGE% 页   %FIRST% %UP_PAGE% %LINK_PAGE% %DOWN_PAGE% %END%');
        $show=$page->show();        
        $stafflist=D('Staff')     
        ->limit($page->firstRow.','.$page->listRows)
        ->order('travelday desc')
        ->select();
        $this->assign('page',$show);
        $this->assign('stafflist',$stafflist);
        $this->assign('title','出差统计页面');
        $this->display('Check_list');
    }
}